import request from '@/utils/request'

// 查询景区门票基础列表
export function listScenic(query) {
  return request({
    url: '/ticket/business/list',
    method: 'get',
    params: query
  })
}

// 查询景区门票基础详细
export function getScenic(activityId) {
  return request({
    url: '/ticket/business/' + activityId,
    method: 'get'
  })
}

// 新增景区门票基础
export function addScenic(data) {
  return request({
    url: '/ticket/business',
    method: 'post',
    data: data
  })
}

// 修改景区门票基础
export function updateScenic(data) {
  return request({
    url: '/ticket/business',
    method: 'put',
    data: data
  })
}

// 删除景区门票基础
export function delScenic(activityIds) {
  return request({
    url: '/ticket/business/' + activityIds,
    method: 'delete'
  })
}

// 查询景区信息
export function getListTicOherBase() {
  return request({
    url: '/ticket/scenic/listTicOherBase?otherBaseType='+2,
    method: 'get'
  })
}

// 上架
export function getOnshelf(activityId) {
  return request({
    url: '/ticket/business/onshelf/' + activityId,
    method: 'get'
  })
}
// 下架
export function getOffshelf(activityId) {
  return request({
    url: '/ticket/business/offshelf/' + activityId,
    method: 'get'
  })
}